<%@ page import="java.util.Date" %>
<%@ page import="java.text.SimpleDateFormat" %><%--
  Created by IntelliJ IDEA.
  User: whb
  Date: 2024/1/20
  Time: 14:46
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head>
    <title>out对象</title>
</head>
<body>
<%
    Date date=new Date();
    SimpleDateFormat sdf =new SimpleDateFormat("yyyy年MM月dd日 HH:mm:ss");
    String formatDate = sdf.format(date);
%>
<h3>
    今天是:
    <%=formatDate%>
</h3>
<hr/>
<h3>
    今天是:
    <%
        out.println(formatDate);
    %>
</h3>
</body>
</html>
